package com.jingdun.sport.api.security;

import com.jingdun.sport.security.token.MyAuthenticationToken;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.springframework.security.core.userdetails.UserDetails;

@Getter
@Setter
@NoArgsConstructor
public class AppAuthenticationToken extends MyAuthenticationToken {

    private int grant_type;

    private String inviteUserId;

    private boolean registerIfNotExist;

    private String nickname;
    private String headImg;
    private Integer sex;
    private String province;
    private String city;
    private String unionId;

   public AppAuthenticationToken(UserDetails principal, Object credentials) {
        super(principal, credentials, principal.getAuthorities());
    }
}